import Mock from 'mockjs'
import user from './user'
import permission from './permission'

Mock.mock('/api/home/getData', () => {
  // 拦截到请求后的处理逻辑
  console.log('拦截到了')
})

// 用户列表数据
Mock.mock('/api/user/add', 'post', user.createUser)
Mock.mock('/api/user/edit', 'post', user.updateUser)
Mock.mock('/api/user/del', 'post', user.deleteUser)
Mock.mock(/api\/user\/getUser/, 'get', user.getUserList)
// Mock.mock('/api/user/getUser', 'get', user.getUserList)

Mock.mock(/api\/permission\/getMenu/, 'post', permission.getMenu)
